package com.yzt.zhuju.network.entity.sysConfig;

import android.text.TextUtils;

/**
 * author : bob
 * date   : 2022/11/29
 * desc   : 系统配置
 */
public class SystemConfigBean {

    /**
     * 融云公共聊天室房间id
     */
    private String onlineChatRoomId;

    /**
     * 后台配置项
     */
    private BackConfigParamer backConfigParameters;

    /**
     * APP最新版本号
     */
    private String versionCode;

    /**
     * 广告列表对象
     */
    private AdvBannerList startPageAdv;

    /**
     * 是否显示手机号登录
     */
    private boolean showPhoneLogin;

    /**
     * 是否处于审核中
     * 如果是在审核中的版本，那么用户将不会显示金币模块，匹配也将不会显示价格
     */
    private boolean isExamine;

    /**
     * 隐私协议
     */
    private String yinsi;

    /**
     * 用户协议
     */
    private String userxieyi;

    /**
     *  是否显示广告
     */
    private boolean isShowAds;


    public boolean isShowAds() {
        return isShowAds;
    }

    public void setShowAds(boolean showAds) {
        isShowAds = showAds;
    }

    public boolean isExamine() {
        return isExamine;
    }

    public void setExamine(boolean examine) {
        isExamine = examine;
    }

    public boolean isShowPhoneLogin() {
        return showPhoneLogin;
    }

    public void setShowPhoneLogin(boolean showPhoneLogin) {
        this.showPhoneLogin = showPhoneLogin;
    }

    public BackConfigParamer getBackConfigParameters() {
        if (backConfigParameters == null) {
            return new BackConfigParamer();
        }
        return backConfigParameters;
    }

    public void setBackConfigParameters(BackConfigParamer backConfigParameters) {
        this.backConfigParameters = backConfigParameters;
    }

    public static class BackConfigParamer {

        // 填性别界面模式1-弹窗 2-页面
        private int selectGenderMode;

        public int getSelectGenderMode() {
            return selectGenderMode;
        }

        public void setSelectGenderMode(int selectGenderMode) {
            this.selectGenderMode = selectGenderMode;
        }

    }

    public String getVersionCode() {
        if (TextUtils.isEmpty(versionCode) || TextUtils.equals(versionCode, "null")) {
            return "0";
        }
        return versionCode;
    }

    public void setVersionCode(String versionCode) {
        this.versionCode = versionCode;
    }

    public String getOnlineChatRoomId() {
        if (TextUtils.isEmpty(onlineChatRoomId)) {
            onlineChatRoomId = "88888888";
        }
        return onlineChatRoomId;
    }

    public void setOnlineChatRoomId(String onlineChatRoomId) {
        this.onlineChatRoomId = onlineChatRoomId;
    }

    public AdvBannerList getStartPageAdv() {
        return startPageAdv;
    }

    public void setStartPageAdv(AdvBannerList startPageAdv) {
        this.startPageAdv = startPageAdv;
    }

    public String getYinsi() {
        return yinsi;
    }

    public void setYinsi(String yinsi) {
        this.yinsi = yinsi;
    }

    public String getUserxieyi() {
        return userxieyi;
    }

    public void setUserxieyi(String userxieyi) {
        this.userxieyi = userxieyi;
    }

    @Override
    public String toString() {
        return "SystemConfigBean{" +
                "onlineChatRoomId='" + onlineChatRoomId + '\'' +
                ", backConfigParameters=" + backConfigParameters +
                ", versionCode='" + versionCode + '\'' +
                ", startPageAdv=" + startPageAdv +
                ", showPhoneLogin=" + showPhoneLogin +
                ", isExamine=" + isExamine +
                ", yinsi='" + yinsi + '\'' +
                ", userxieyi='" + userxieyi + '\'' +
                '}';
    }
}
